

import smtplib

from_addr = 'pytest@localhost' 
to_addrs = ['console']

content = '''

bla bla 


!!!

'''

content = ( "From: %s\r\n"
            "To: %s\r\n"
            "Subject: Test Mail...\r\n"
            "\r\n%s"
       % ( from_addr, ", ".join( to_addrs ), content ) )

server = smtplib.SMTP( 'localhost', 2500 )
server.sendmail( from_addr, to_addrs, content )
server.quit()

